package com.example.fishscavengerhunt;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.widget.CheckBox;
import android.widget.EditText;

public class QRScan extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_qrscan);
		IntentIntegrator integrator = new IntentIntegrator(this);
		Intent myIntent = new Intent(QRScan.this, SelectFish.class);
		QRScan.this.startActivity(myIntent);
    	integrator.initiateScan();
	}
	
	public void onActivityResult(int requestCode, int resultCode, Intent intent) {
		IntentResult scanResult = IntentIntegrator.parseActivityResult(requestCode, resultCode, intent);
		  if (scanResult != null) {
		    // handle scan result
		  } 
		  else {
			  QRScan.this.finish();
		  }
		}

}
